﻿//Copyright (c) Microsoft Corporation.  All rights reserved.

using System;
using System.Collections.Generic;

namespace Microsoft.Ted.Wacel.Base
{
    /// <summary>
    /// IDataProvider defines methods that need to be implemented by a Data Provider. 
    /// </summary>
    public interface IDataProvider
    {
        void Put(string key, object value, string partition = null);
        object Get(string key, string partition = null, Type typeHint = null, Type typeHint2 = null);
        void Update(string key, object value, string partition = null);
        void Delete(string key, string partition = null);
        IEnumerable<KeyValuePair<string, object>> BulkGet(List<string> keys, string partition = null, Type typeHint = null, Type typeHint2 = null);
        void BulkPut(IEnumerable<KeyValuePair<string, object>> values, string partition = null);
        void Clear();
        DataProviderConfiguration Configuration { get; set; }
        IEnumerable<KeyValuePair<string, object>> GetAll(string partition = null, Type typeHint = null, Type typeHint2 = null);

        IDataProvider Clone(string newName);
    }
}
